package com.xiaoyu.awakening.ai.common.api;

import com.xiaoyu.awakening.ai.common.entity.dto.*;
import com.xiaoyu.awakening.common.core.dto.Result;
import io.swagger.v3.oas.annotations.media.Schema;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;

import java.util.List;

/**
 * LLM相关服务接口
 *
 * @author wangxiaoyu
 * @date 2024/7/29 11:57
 * @since v1.0
 */
@RequestMapping("/api/v1/awk-tool")
@Schema(name = "awk-tool-api")
public interface IAwkToolControllerApi {
    /**
     * embeddings
     *
     * @param awkEmbeddingsReqDto 向量化请求
     * @return Result<AwkEmbeddingsResDto> 向量化结果
     * @author wangxiaoyu
     * @date 2024/7/29 16:54
     * @since v1.0
     */
    @PostMapping(value = "/embeddings")
    Result<AwkEmbeddingsResDto> embeddings(@RequestBody AwkEmbeddingsReqDto awkEmbeddingsReqDto);

    @PostMapping(value = "/rerank")
    Result<List<Double>> rerank(@RequestBody AwkRerankReqDto awkRerankReqDto);


}
